package com.demo.clazz;

public class SprinklerSystem {
    private String value1,value2,value3,value4,value5;
    private WaterSouurce waterSouurce = new WaterSouurce();
    private int i;
    private float f;
    public String toString(){
        return "value1 = " + value1+",value2 = " + value2+",value3 = " + value3+",i = " + i + ",f = " + f + ", waterSouurce = "+waterSouurce;
    }

    public static void main(String[] args) {
        SprinklerSystem sprinklerSystem = new SprinklerSystem();
        System.out.println(sprinklerSystem);
    }
}



class WaterSouurce{
    private String s = "chegyuang";

    public WaterSouurce(){
        System.out.println("WaterSouurce()");
        s = "constructed";
    }
    public String toString(){
        return s;
    }
}